registerTests([
function DefaultIfEmpty_Test_0()
{
	var myArray = [1, 2, 3];
	var result = myArray.DefaultIfEmpty();
	
	Assert.areEqual(result.length, 3);
	Assert.areEqual(result[0], 1);
	Assert.areEqual(result[1], 2);
	Assert.areEqual(result[2], 3);
},
function DefaultIfEmpty_Test_1()
{
	var myArray = [];
	var result = myArray.DefaultIfEmpty();

	Assert.areEqual(result.length, 1);
	Assert.areEqual(result[0], null);
},
function DefaultIfEmpty_Test_Default_0()
{
	var myArray = [1, 2, 3];
	var result = myArray.DefaultIfEmpty(32);
	
	Assert.areEqual(result.length, 3);
	Assert.areEqual(result[0], 1);
	Assert.areEqual(result[1], 2);
	Assert.areEqual(result[2], 3);
},
function DefaultIfEmpty_Test_Condition_1()
{
	var myArray = [];
	var result = myArray.DefaultIfEmpty(32);

	Assert.areEqual(result.length, 1);
	Assert.areEqual(result[0], 32);
}
]);